package com.filldream.fastboot.common.okutil.cls.dto;

import lombok.Data;

@Data
public class ClsAnchorDTO {

    private String symbolCode;

    private String symbolName;

    private Long articleId;

    private String cTime;

    private Boolean isUp;

    public String getKey(){
        return symbolCode + "_" + symbolCode;
    }

    public ClsNewsSimpleItem toClsNewsSimpleItem(){
        ClsNewsSimpleItem clsNewsSimpleItem = new ClsNewsSimpleItem();
        clsNewsSimpleItem.setId( getKey() );
        clsNewsSimpleItem.setIsTop(true);
        clsNewsSimpleItem.setTitle( "板块:" + symbolName + (isUp  ? " ↑ " : " ↓ " ) + cTime );
        return clsNewsSimpleItem;
    }

}
